package com.lanchetech.common.enums;

import lombok.Getter;

@Getter
public enum LogisticsStatusEnum {
    UNDO((byte) 0, "未发货"),
    DONE((byte) 1, "已发货"),
    RECEIVED((byte) 2, "已签收"),
    ;

    private Byte status;
    private String remark;

    LogisticsStatusEnum(Byte status, String remark) {
        this.status = status;
        this.remark = remark;
    }

    public static String getRemarkByStatus(Byte status) {
        for (LogisticsStatusEnum logisticsStatus : LogisticsStatusEnum.values()) {
            if (logisticsStatus.getStatus().equals(status)) {
                return logisticsStatus.getRemark();
            }
        }
        return "";
    }
}
